home *** CD-ROM | disk | FTP | other *** search
- Path: oxy.rust.net!usenet
- From: ebennett@rust.net
- Newsgroups: comp.lang.c++
- Subject: Re: Basic header file broblem in BC 4.5
- Date: Tue, 23 Jan 1996 05:02:27 GMT
- Organization: Rust Net - High Speed Internet in Detroit 810-642-2276
- Message-ID: <4e1fip$do7@oxy.rust.net>
- References: <4du8q0$k1h@yuggoth.ucsb.edu>
- NNTP-Posting-Host: liv-18.rust.net
- X-Newsreader: Forte Free Agent 1.0.82
-
- "Peter V. Kharchenko" <peter@cs.ucsb.edu> wrote:
-
- >Hi everyone,
-
- > I've been trying for a several days to correct my project file in some way to
- >make it work. Here's the situation that I have:
-
- > I have two header files (.hpp) with little (.cpp) files corresponding to them,
- >and one file that includes main() function in it. I am using Borland C 4.5. I
- >created a project and included there two .cpp files corresponding to headers
- >and the main file. The problem is that Linker does not recognize the functions
- >described in one of the .cpp (.hpp) files. The whole thing works perfectly if
- >I just attach function bodies (ones that are normally in little .cpp file) to
- >the .hpp file. Anyway .. I'll enclose the files later on.
-
- > Actual problem: I get a linker error: undifined object in task01.cpp :
- >stack<complex>::<complex> pop()
- >etc. on all the other stack functions. (notice that all the functions
- >described in complex.cpp are workign just fine, it's just the stack unit that
- >is screwed)
-
- This code is dealing with templates. In order to separate the
- template definition from its implementation, you need to use the
- compilers -Jg switches. These are discussed in the Programmers Guide.
-
- Earl
-
-
-